<%--
  Created by IntelliJ IDEA.
  User: Lenovo
  Date: 2021/5/26
  Time: 15:07
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%
    String path = request.getContextPath();
%>
<html>
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="lib/layui.js"></script>
    <script src="./lib/js/jquery.js"></script>
    <link rel="stylesheet" href="lib/layui-v2.6.7/layui/css/layui.css" media="all">
    <link rel="preload" href="//at.alicdn.com/t/font_2081251_1w6wnhjqy8f.woff2" as="font" type="font/woff2"
          crossorigin="anonymous">
    <!--    style-->
    <style>
        @font-face {
            font-family: 'iconfont';
            src: url('//at.alicdn.com/t/font_2081251_1w6wnhjqy8f.woff2?t=1621867815342') format('woff2'),
            url('//at.alicdn.com/t/font_2081251_1w6wnhjqy8f.woff?t=1621867815342') format('woff'),
            url('//at.alicdn.com/t/font_2081251_1w6wnhjqy8f.ttf?t=1621867815342') format('truetype');
        }

        .iconfont {
            font-family: "iconfont" !important;
            font-size: 40px;
            font-style: normal;
            -webkit-font-smoothing: antialiased;
            -moz-osx-font-smoothing: grayscale;
        }

        #header {
            color: white;
            text-align: center;
            padding: 5px;
        }

        #nav {
            line-height: 30px;
            height: 300px;
            width: 100px;
            float: left;
            padding: 5px;
        }

        #section {
            width: 350px;
            float: left;
            padding: 10px;
        }

        #footer {
            color: #ffffff;
            clear: both;
            text-align: center;
            padding: 5px;
        }
    </style>
</head>
<script type="text/javascript">
    function ajaxFun() {
        $.ajax({
            url: "../SelectServlet", //
            data: {dailyWork:100},
            type: "post",          //传数据的方式
            dataType:"json",
            success: function (admin) {
                // alert("查询成功！");
                $("#dailyWork").val(admin[0].dailyWork);
                $("#midExamResults").val(admin[0].midExamResults);
                $("#examResults").val(admin[0].examResults);
                $("#totalMark").val(admin[0].totalMark);
            }
        });
    }
</script>
<body>
<fieldset class="layui-elem-field layui-field-title" style="margin-top: 30px;">
    <legend align="center">教务系统登陆</legend>
</fieldset>
<!--头部div-->
<div id="header">
    <ul class="layui-nav" lay-filter="">
        <li class="layui-nav-item"><a href="login.jsp">登陆/注册</a></li>
        <li class="layui-nav-item layui-this"><a href="https://www.nciae.edu.cn/">学院官网</a></li>
        <li class="layui-nav-item" align="right">
            <a href="javascript:;">帮助</a>
            <dl class="layui-nav-child"> <!-- 二级菜单 -->
                <dd><a href="">qq联系</a></dd>
                <dd><a href="">帮助</a></dd>
            </dl>
        </li>
        <li class="layui-nav-item"><a href="">社区</a></li>
        <li class="layui-nav-item"><a href="">退出</a></li>
    </ul>
</div>
<!--左面的div-->
<div id="nav" class="layui-collapse" lay-accordion>
    <img src="img/R7dad6a78921942499787acfff48f01ea.jpg" width="1900" height="800">
</div>
<div id="section" class="layui-collapse" lay-accordion>
    <div class="layui-colla-item">
        <h2 class="layui-colla-title">信息查询</h2>
        <table>
            <tr>
                <td><span class="iconfont">&#xe82e;</span></td>
                <td><span class="iconfont">&#xe82e;</span></td>
                <td><span class="iconfont">&#xe82e;</span></td>
                <td><span class="iconfont">&#xe82e;</span></td>
            </tr>
            <tr>
                <td>
                    <form id="form">
                        <input type="button" value="学生信息查询" onclick="ajaxFun()"/>
                        <%--                        <button type="button" onclick="ajaxFun(this)">学生信息查询</button>--%>
                    </form>
                    <input type="text" id="dailyWork">
                    <input type="text" id="midExamResults">
                    <input type="text" id="examResults">
                    <input type="text" id="totalMark">
                </td>
                <td><a>考试信息查询</a></td>
                <td><a>成绩信息查询</a></td>
                <td><a>课表信息查询</a></td>
                <a>123<%=request.getSession().getAttribute("student")%>
                </a>
            </tr>
        </table>
    </div>
    <div class="layui-colla-item">
        <h2 class="layui-colla-title">选课</h2>
        <div class="layui-colla-content layui-show">内容区域</div>
    </div>
    <!--    教师功能界面-->
    <div class="layui-colla-item" id="layui-colla-item">
        <h2 class="layui-colla-title">教师管理</h2>
        <div class="layui-colla-content layui-show">内容区域</div>
    </div>
</div>
<div id="footer">
    <button></button>
</div>
<script>
    layui.use('element', function () {
        var element = layui.element;

        //…
    });
</script>
</body>
</html>
